package org.ssm.learn;

/**
 * 生产者
 */
public class Producer implements Runnable {

    private Info info = null;

    Producer(Info info) {

        this.info = info;

    }

    public void run() {
        boolean flag = false;
        for (int i = 0; i < 25; ++i) {
            if (flag) {

                this.info.set("20", 20);
                flag = false;
            } else {
                this.info.set("100", 100);
                flag = true;
            }
        }
    }

}